package dao.tables;

import java.sql.Date;

import dao.AbstractTable;

public class PERSONNE extends AbstractTable {
	private long	id				= 0;
	private String	nom				= null;
	private String	prenom			= null;
	private String	civilite		= null;
	private Date	dateDeNaissance	= null;

	public PERSONNE() {}

	public PERSONNE(long id, String nom, String prenom, String civilite, Date dateDeNaissance) {
		this.id = id;
		this.nom = nom;
		this.prenom = prenom;
		this.civilite = civilite;
		this.dateDeNaissance = dateDeNaissance;
	}

	@Override
	public String getValue() {
		return this.getNom();
	}

	public void setId(long id) {
		this.id = id;
	}

	public long getId() {
		return id;
	}

	public void setNom(String nom) {
		this.nom = nom;
	}

	public String getNom() {
		return nom;
	}

	public void setPrenom(String prenom) {
		this.prenom = prenom;
	}

	public String getPrenom() {
		return prenom;
	}

	public void setCivilite(String civilite) {
		this.civilite = civilite;
	}

	public String getCivilite() {
		return civilite;
	}

	public void setDateDeNaissance(Date dateDeNaissance) {
		this.dateDeNaissance = dateDeNaissance;
	}

	public Date getDateDeNaissance() {
		return dateDeNaissance;
	}

	public String toString() {
		String str = "PERSONNE {\n";
		str += "\tCIVILITE : " + this.getCivilite() + "\n";
		str += "\tNOM : " + this.getNom() + "\n";
		str += "\tPRENOM : " + this.getPrenom() + "\n";
		str += "\tDATE DE NAISSANCE : " + this.getDateDeNaissance() + "\n}";
		str += ".....................................................\n";
		return str;
	}
}
